/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package lanSimulation.tests;
///import lanSimulation.internals.Document;
import java.io.StringWriter;
import lanSimulation.internals.Document;
import lanSimulation.LogManager;
import junit.framework.TestCase;
/**
 *
 * @author Administrator
 */
public class DocumentTest extends TestCase{

    public void testGetText(){
        Document doc = new Document("this is test document");
        assertEquals("this is test document", doc.getText());
    }

    public void testPrint(){
        Document doc = new Document ("this is test document");
        StringWriter writer = new StringWriter();
        LogManager logman=new LogManager(writer);
        doc.print(logman);
        assertEquals("this is test document",writer.getBuffer().toString());
  }
}
